﻿<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>@ViewBag.Title - My ASP.NET Application</title>
    @Styles.Render("~/Content/css")
    @Scripts.Render("~/bundles/modernizr")
    @Scripts.Render("~/bundles/jquery")
    <script src="@Url.Content("~/Scripts/CRMExamScripts/Application.js")"></script>
    <script src="@Url.Content("~/Scripts/Calendar/fullcalendar.js")"></script>
    <script src="@Url.Content("~/Scripts/Calendar/jquery-ui-timepicker-addon.js")"></script>


</head>
<body id="body">
    <div class="navbar navbar-inverse navbar-fixed-top">
        <div class="container">
            <div class="navbar-header">
                <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                </button>
               
            </div>
            <div class="navbar-collapse collapse">
                @{if (User.Identity.IsAuthenticated)
                {
                    @Html.Partial("_Menu")
                }
                
                }
               
                @Html.Partial("_LoginPartial")
            </div>
        </div>
    </div>
    <div class="container body-content">
        <div style="float:left;margin-right:10px;width:100%">
            <table>
                <tr>
                    <td valign="top" style="padding-right:10px">@Html.Action("Chat", "Chat")</td>
                    <td style="width:100%">
                        <div style="float:left;width:100%">
                            @RenderBody()
                            @Html.Partial("_Flash")
                        </div>
                    </td>
                </tr>
            </table>
        </div>
    </div>
    @if (Request.IsAuthenticated)
    {        
        @Html.Action("BackgroundPicture", "Branding")
       
        var cookie = Request.Cookies["branding"];
        <input id="temp" type="hidden" value=@cookie.Value />
     
        <script>
            $("#body").css('background-image', 'url(' + $("#temp").val() + ')');
            $("#body").css(
                'background-size: cover;',
                '-webkit-background-size: cover;',
                '-moz-background-size: cover;',
                '-o-background-size: cover;'); // Bakgrunden täcker hela skärmen
        </script>
    }

    @Scripts.Render("~/bundles/bootstrap")
    @RenderSection("scripts", required: false)
    <br />
</body>
</html>
